import { createApp } from 'vue'
import { setupStore } from './stores'
import i18n from './i18n'
import 'reset-css' // 全局重置样式
import router from './router' // 路由
import './router/permission' // 路由守卫
// import 'amfe-flexible' // 移动端适配
import './Utils/polyfill' // 去除谷歌的touch事件警告
import App from './App.vue'
import { setDomFontSize } from './Utils/dom'

import CardBox from './components/Box/CardBox.vue'
import Layout from './components/Layout/Layout.vue'
import TitleCom from './components/Layout/Title/TitleCom.vue'
import GroupBox from './components/GroupBox/GroupBox.vue'
setDomFontSize()

const app = createApp(App)
app.component('CardBox', CardBox)
app.component('Layout', Layout)
app.component('TitleCom', TitleCom)
app.component('GroupBox', GroupBox)

setupStore(app)

app.use(i18n)

app.use(router)

app.mount('#app')
